package com.video.dao;

import com.video.bean.Vip;
import com.video.utils.ResultMap;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface VipDao {

    /**
     * 查询所有vip
     * @return
     */
    public List<Vip> selectAllVip();

    /**
     * 根据vtId查询vip
     * @return
     */
    public Vip selectVipByVtid(String vtId);

    /**
     * 创建vip
     * @param vip
     * @return
     */
    public int createVip(Vip vip);

    /**
     * 根据id修改vip信息
     * @param vip
     * @return
     */
    public int updateVipByVtId(Vip vip);

    /**
     * 根据id删除vip
     * @param vtId
     * @return
     */
    public int deleteVipByVtid(String vtId);

    /**
     * 查询当前用户是否在vip表中存在
     * @param username
     * @return
     */
    public Vip selectVipByUsername(String username);

    /**
     *  充值会员
     * @param vip
     * @return
     */
    public int insertMember(Vip vip);
}
